import { axiosGet } from '@/utils/request'
import type { HotWangzhanRes, HouseParams, HouseResData, SchoolResData, ScreenOtherRes, WeekDataRes } from './types/dataAsset';
import { Res } from './types/common';

// 房屋数据
export function getScreenHouseData(params: HouseParams): Res<HouseResData> {
  return axiosGet(`/pt-cms-api/screen/house?type=${params.type}`)
}

// 学校数据
export function getScreenSchoolData(): Res<SchoolResData> {
  return axiosGet('/pt-cms-api/screen/school')
}

// 数据趋势
export function getWeekData(): Res<WeekDataRes> {
  return axiosGet('/pt-cms-api/screen/weekData')
}

// 网站
export function getHotWangzhanData(): Res<HotWangzhanRes> {
  return axiosGet('/pt-cms-api/screen/wangzhan')
}

// 其他数据采集
export function getScreenOtherData(): Res<ScreenOtherRes> {
  return axiosGet('/pt-cms-api/screen/qita')
}